clc, clear, close all
x = linspace(0, 3*pi, 40);
y1 = sin(x);
y2 = 0.1*x-0.5;
y3 = cos(x+pi/2);
figure
% 黑色实线, 圆圈标记, 线宽1.1, 标记内部填充颜色从网上找好看的配色
plot(x, y1, 'ok-', 'linewidth', 1.1, 'markerfacecolor', [36, 169, 225]/255)
hold on
plot(x, y2, 'ok-', 'linewidth', 1.1, 'markerfacecolor', [29, 191, 151]/255)
% 设置坐标轴范围
axis([0, 3*pi, -1.2 1.2])
% 坐标轴边框线宽1.1, 坐标轴字体与大小为Times New Roman和16
set(gca, 'linewidth', 1.1, 'fontsize', 16, 'fontname', 'times')
xlabel('Time (s)')
ylabel('Displacement (m)')
legend('sin(x)', '0.1x-0.5')